fs/xfs: Fix grub_xfs_iterate_dir return value in case of failure
authorEgor Ignatov <egori@altlinux.org>
Thu, 23 Jan 2025 17:44:14 +0000 (20:44 +0300)
committerMiao Wang <shankerwangmiao@gmail.com>
Sun, 15 Feb 2026 13:50:20 +0000 (13:50 +0000)
commitbb113733f2e76bee5eda35e6c6277d1f053bc816
treedc9c8651662f6e93c695e463030c48d8a83fa4a4
parent1880b017f947948d4084f97e7f8e6228808a3e40
fs/xfs: Fix grub_xfs_iterate_dir return value in case of failure

Commit ef7850c757 introduced multiple boundary checks in grub_xfs_iterate_dir()
but handled the error incorrectly returning error code instead of 0.

Also change the error message so that it doesn't match the message
in grub_xfs_read_inode().

Fixes: ef7850c757 (fs/xfs: Fix issues found while fuzzing the XFS filesystem)
Signed-off-by: Egor Ignatov <egori@altlinux.org>
Gbp-Pq: Topic cve-2025-jan
Gbp-Pq: Name fs-xfs-Fix-grub_xfs_iterate_dir-return-value-in-case-of-f.patch
grub-core/fs/xfs.c